package com.hp.siminterface.webservice.impl;

import java.util.List;

import com.hp.siminterface.domain.InstalledController;
import com.hp.siminterface.persistence.InstalledControllerMapper;
import com.hp.siminterface.webservice.InstalledControllerService;

public class InstalledControllerServiceImpl implements
		InstalledControllerService {
	private InstalledControllerMapper installedControllerMapper;

	@Override
	public InstalledController[] getInstalledControllerInfo() {
		List<InstalledController> installedControllers = installedControllerMapper
				.selectInstalledController();
		InstalledController[] installedControllerArray = new InstalledController[installedControllers
				.size()];
		int i = 0;
		for (InstalledController installedController : installedControllers) {
			installedControllerArray[i] = installedController;
			i++;
		}
		return installedControllerArray;
	}

	public void setInstalledControllerMapper(
			InstalledControllerMapper installedControllerMapper) {
		this.installedControllerMapper = installedControllerMapper;
	}

}
